class TwittersController < ApplicationController

  def index
  end
  def create
    @twitter = Twitter.new(twitter_param)
    @twitter.user_id = current_user.id
    @twitter.save
    respond_to do |format|
      format.js
    end
  end

  def twitter_param
    params.require(:twitter).permit(:content)
  end
end
